package com.bupt.ilink.entity.store;


import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.bupt.ilink.typehandler.JsonNodeTypeHandler;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.JsonNode;
import lombok.AllArgsConstructor;
import lombok.Data;

import java.util.Date;

@Data
@AllArgsConstructor
@TableName("tb_flow")
public class Flow {
    @TableId
    private String flowId;

    private String name;
    private String description;
    private String icon;
    private String iconBgColor;
    private Boolean isComponent;
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updatedAt;
    private Boolean webhook;
    private String endpointName;
    @TableField(typeHandler = JsonNodeTypeHandler.class)
    private JsonNode data;

    private String userId;
    private String folderId;
}
